/*
Package bootstap
@Author   : Uyynot
@Email    : uyynot@qq.com
@Time     : 2024/2/20 17:46
@File     : redis.go
@Project  : gohub
@Desc     :
*/
package bootstap

import (
	"fmt"
	"gohub/pkg/config"
	"gohub/pkg/redis"
)

// SetupRedis 初始化Redis
func SetupRedis() {
	//建立Redis连接
	redis.ConnectRedis(
		fmt.Sprintf("%v:%v", config.GetString("redis.host"), config.GetString("redis.port")),
		config.GetString("redis.username"),
		config.GetString("redis.password"),
		config.GetInt("redis.database"),
	)
}
